<?php
/**
 * Created by PhpStorm.
 * User: yuyi
 * Date: 17/8/4
 * Time: 21:26
 */
include __DIR__."/../vendor/autoload.php";
define("HOME", dirname(__DIR__));
define("WING_DEBUG",  true);
$pdo = new \Wing\Library\PDO();

$sql = "SHOW MASTER STATUS";
$res = $pdo->row($sql);
var_dump($res);

$sql  = 'show binary logs';
$res = $pdo->query($sql);
var_dump($res);
//$sql1 = 'update new_yonglibao_c.bl_city set provinces_id=(provinces_id+1) where id=5753598';
//$sql2 = 'update new_yonglibao_c.bl_city set provinces_id=(provinces_id-1) where id=5753598';
//
//$sql1 = 'update xsl.x_messages set phone=(phone+1) where 1';
//$sql2 = 'update xsl.x_messages set phone=(phone-1) where 1';
//
//$sql1 = 'update xl.content_type set sort=(sort+1) where 1';
//$sql2 = 'update xl.content_type set sort=(sort-1) where 1';
//$count = 0;
//while ($count<1000)
//{//$count<10000
//    $count +=2;
//    $pdo->query($sql1);
//    $pdo->query($sql2);
//    echo "事件次数：",$count,"\r\n";
//}